<template>
	<view class="box">
		<tn-tabs :list="list" :isScroll="false" :current="current" name="tabname" @change="change"></tn-tabs>
		<view v-show="current == 0">
			<view class="good">
				<view class="top">
					<view>机芯1</view>
					<view class='kun'>待维修</view>
				</view>
				<view class="bot">所属产品：A型产品</view>
			</view>
			<view class="good">
				<view class="top">
					<view>机芯2</view>
					<view class='kun'>待维修</view>
				</view>
				<view class="bot">所属产品：A型产品</view>
			</view>
			<view class="good">
				<view class="top">
					<view>机芯3</view>
					<view class='kun'>待维修</view>
				</view>
				<view class="bot">所属产品：A型产品</view>
			</view>
			<view class="good">
				<view class="top">
					<view>机芯4</view>
					<view class='kun'>待维修</view>
				</view>
				<view class="bot">所属产品：A型产品</view>
			</view>
			<view class="good">
				<view class="top">
					<view>机芯5</view>
					<view class='kun'>待维修</view>
				</view>
				<view class="bot">所属产品：A型产品</view>
			</view>
		</view>
		<view v-show="current == 1">
			<view class="good">
				<view class="top">
					<view>机芯9</view>
					<view class='kun'>待维修</view>
				</view>
				<view class="bot">所属产品：B型产品</view>
			</view>
			<view class="good">
				<view class="top">
					<view>机芯2</view>
					<view class='kun'>待维修</view>
				</view>
				<view class="bot">所属产品：B型产品</view>
			</view>
			<view class="good">
				<view class="top">
					<view>机芯3</view>
					<view class='kun'>待维修</view>
				</view>
				<view class="bot">所属产品：B型产品</view>
			</view>
			<view class="good">
				<view class="top">
					<view>机芯4</view>
					<view class='kun'>待维修</view>
				</view>
				<view class="bot">所属产品：B型产品</view>
			</view>
			<view class="good">
				<view class="top">
					<view>机芯5</view>
					<view class='kun'>待维修</view>
				</view>
				<view class="bot">所属产品：B型产品</view>
			</view>
		</view>
		<view v-show="current == 2">
			<view class="good">
				<view class="top">
					<view>机芯1</view>
					<view class='kun'>待维修</view>
				</view>
				<view class="bot">所属产品：C型产品</view>
			</view>
			<view class="good">
				<view class="top">
					<view>机芯2</view>
					<view class='kun'>待维修</view>
				</view>
				<view class="bot">所属产品：C型产品</view>
			</view>
			<view class="good">
				<view class="top">
					<view>机芯3</view>
					<view class='kun'>待维修</view>
				</view>
				<view class="bot">所属产品：C型产品</view>
			</view>
			<view class="good">
				<view class="top">
					<view>机芯4</view>
					<view class='kun'>待维修</view>
				</view>
				<view class="bot">所属产品：C型产品</view>
			</view>
			<view class="good">
				<view class="top">
					<view>机芯5</view>
					<view class='kun'>待维修</view>
				</view>
				<view class="bot">所属产品：C型产品</view>
			</view>
		</view>
		<view v-show="current == 3">
			<view class="good">
				<view class="top">
					<view>机芯1</view>
					<view class='kun'>待维修</view>
				</view>
				<view class="bot">所属产品：D型产品</view>
			</view>
			<view class="good">
				<view class="top">
					<view>机芯2</view>
					<view class='kun'>待维修</view>
				</view>
				<view class="bot">所属产品：D型产品</view>
			</view>
			<view class="good">
				<view class="top">
					<view>机芯3</view>
					<view class='kun'>待维修</view>
				</view>
				<view class="bot">所属产品：D型产品</view>
			</view>
			<view class="good">
				<view class="top">
					<view>机芯4</view>
					<view class='kun'>待维修</view>
				</view>
				<view class="bot">所属产品：D型产品</view>
			</view>
			<view class="good">
				<view class="top">
					<view>机芯5</view>
					<view class='kun'>待维修</view>
				</view>
				<view class="bot">所属产品：D型产品</view>
			</view>
		</view>

	</view>
</template>

<script>
	export default {
		data() {
			return {
				list: [{
						tabname: 'A产品'
					},
					{
						tabname: 'B产品'
					},
					{
						tabname: 'C产品'
					},
					{
						tabname: 'D产品'
					}
				],
				current: 0
			}
		},
		methods: {
			change(index) {
				this.current = index;
			}
		}
	}
</script>

<style lang='scss' scoped>
	.box {
		background-color: #f8f8f8;
		min-height: 100vh;
	}

	.good {
		background-color: #fff;
		border-radius: 30rpx;
		margin: 30rpx;

		.top {
			display: flex;
			justify-content: space-between;
			padding: 30rpx 50rpx 10rpx 30rpx;

			.kun {
				background-color: #ff2326;
				width: 100rpx;
				height: 50rpx;
				text-align: center;
				line-height: 50rpx;
				border-radius: 25rpx;
				color: #fff;
			}
		}

		.bot {
			padding: 30rpx 30rpx;
		}
	}
</style>